/**
 * @Title: LotterServiceImpl
 * @Package cn.com.yiqi.wsc.service.lottery.impl
 * @Description: TODO
 * Copyright: Copyright (c) 2016
 * Company: 成都壹柒互动科技有限公司
 * @author 会员系统组-林威
 * @date 2017/2/20 15:51
 * @version V1.0
 */
package cn.com.yiqi.wsc.service.lottery.impl;


import cn.com.yiqi.wsc.dao.lottery.LotteryActivityMapper;
import cn.com.yiqi.wsc.dao.lottery.LotteryItemsMapper;
import cn.com.yiqi.wsc.Ro.LotterVO;
import java.util.List;

import cn.com.yiqi.wsc.entity.lottery.LotteryActivity;
import cn.com.yiqi.wsc.entity.lottery.LotteryItems;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 *
 *@ClassName: LotterServiceImpl
 * Description: TODO
 * @author 会员系统组-林威
 * @date 2017/2/20 15:51
 *
 */
@Service
public class LotterServiceImpl {

    @Autowired
    LotteryItemsMapper lotteryDao;

    @Autowired
    LotteryActivityMapper activityDao;
    /**
     * 大转盘抽奖奖品list
     *
     * */
    public List<LotterVO> findLotters(int activityId,String urlPre) {
        return lotteryDao.findLottersBytype(activityId,urlPre);
    }

    /**
     * 抽奖活动
     * */
    public List<LotteryActivity> findActivity() {
        return activityDao.findActivityUrl();
    }


    /**
     *
     * */
    public LotteryActivity findActivityById(Integer id) {
        return activityDao.findById(id);
    }
}

